App.config(['$stateProvider', '$urlRouterProvider', function ($stateProvider, $urlRouterProvider) {
    $urlRouterProvider.otherwise('login');
    $stateProvider
        .state('home', {
            url: '/home',
            templateUrl: './src/views/home.html'
        })
        .state('login', {
            url: '/login',
            templateUrl: './src/views/login.html'
        })
        .state('register', {
            url: '/register',
            templateUrl: './src/views/register.html'
        })
        .state('shopCart', {
            url: '/shopCart',
            templateUrl: './src/views/shopCart.html'
        })
        .state('pro_categories', {
            url: '/pro_categories',
            templateUrl: './src/views/pro_categories.html'
        })
        .state('pro_search?search', {
            url: '/pro_search',
            templateUrl: './src/views/pro_search.html'
        })
        .state('pro_list', {
            url: '/pro_list?proid?search',
            templateUrl: './src/views/pro_list.html'
        })
        .state('pro_details', {
            url: '/pro_details?proid',
            templateUrl: './src/views/pro_details.html'
        })
        .state('order', {
            url: '/order',
            templateUrl: './src/views/order.html'
        })
        .state('confirm_order', {
            url: '/confirm_order',
            templateUrl: './src/views/confirm_order.html'
        })
        .state('user', {
            url: '/user',
            templateUrl: './src/views/user.html'
        })
        .state('payS', {
            url: '/payS',
            templateUrl: './src/views/payS.html'
        })
        .state('payF', {
            url: '/payF',
            templateUrl: './src/views/payF.html'
        })
	.state('pay',{
            url: '/pay',
            templateUrl: './src/views/pay.html'
        })
}]);
